home *** CD-ROM | disk | FTP | other *** search
/ Commodore Free 38 / Commodore_Free_Issue_38_2010_Commodore_Computer_Club.d64 / pla replacement < prev    next >
Text File  |  2023-02-26  |  8KB  |  256 lines

  1.  
  2.  
  3.  
  4. *************************************
  5.  WORKING PLA REPLACEMENT FOR MY C64
  6. *************************************
  7.  
  8. Hello All,
  9. Just wanted to let all of you know
  10. that I FINALLY created a WORKING PLA
  11. Replacement for my C64. I have only
  12. tested it in one of the Breadbox
  13. C64's so far.
  14.  
  15. I use Ray Carlsons Diagram,
  16. http://personalpages.tds.net
  17. /{$de}rcarlsen/tdsweb/EPROMPLA/
  18. eprompla.jpg
  19.  
  20. Info:
  21. http://personalpages.tds.net
  22. /{$de}rcarlsen/tdsweb/EPROMPLA/
  23. eprompla.txt
  24.  
  25. C64 PLA chip replacement using an
  26. EPROM and adaptor latest updates and
  27. corrections 11-20-07
  28.  
  29. The supply of replacement ICs for
  30. Commodore computers has been
  31. shrinking since Commodore stopped
  32. making chips more than a decade ago.
  33. Most of what you find now are used
  34. "pulls" from existing equipment,
  35. some good, some bad. The most common
  36. failure in the C64 has been IC U17,
  37. a pre-programmed 28 pin generic
  38. 82S100 programmable logic array or
  39. PLA. That IC normally runs very hot
  40. and should have been heat sinked. It
  41. was in later versions of the 64.
  42. Since the supply of obsolete
  43. unprogrammed 82S100 ICs has likewise
  44. dried up, a way to replace the
  45. Commodore PLA with some other kind
  46. of device has been discussed many
  47. times on the newsgroup comp.sys.cbm
  48. and elsewhere. A 64K EPROM
  49. programmed with the code from a
  50. working PLA and rewired via a
  51. circuit board or other adaptor to
  52. cross-connect a few pins has had
  53. some success in duplicating the
  54. logic of the original PLA. There are
  55. several different versions of this
  56. modification on the internet. Note
  57. that the code for the EPROM must
  58. match the pinout of the adaptor that
  59. goes with it! The modification I
  60. found takes only a few pin swaps to
  61. make it work. The other one takes
  62. more. Guess which one I chose to
  63. use? ;-)
  64.  
  65. With a "burner" on my PC, I began
  66. experimenting with various types of
  67. EPROMs when my stock of PLA chips
  68. was depleted. The original PLA
  69. averaged a rather speedy 50nS. The
  70. best information I had early on was
  71. that a very fast IC was needed to
  72. simulate it. Most reprogrammable UV
  73. EPROMs are much slower at 150 to
  74. 300nS and I already had some of
  75. those. A one-time-programmable (OTP)
  76. Atmel AT27C512R45 seemed fast enough
  77. with its 45nS response time and they
  78. were cheap at the time, so a batch
  79. of the OTP chips was purchased and
  80. some adaptors made out of
  81. "sandwiched" IC sockets. One adaptor
  82. was needed to extract the PLA code
  83. and get it into my computer, and
  84. another adaptor to make the
  85. programmed EPROM work in the C64.
  86. I'm putting up both adaptor
  87. schematics and the code on my site
  88. if anyone wants to make their own
  89. substitute PLA. The resulting
  90. replacement ICs do work in many C64
  91. boards but not in others, even ones
  92. with the same board number. Now to
  93. the reasons...
  94.  
  95. One of my C64 boards (250407) will
  96. work with just about any PLA
  97. substitute EPROM from the slowest
  98. 250nS to the fastest OTP. Other
  99. boards are -very- fussy about the
  100. replacement PLA. Results with those
  101. boards varied from blank screen to
  102. less than the normal bytes free at
  103. startup to random character colour
  104. errors or program crashes... common
  105. indicators of a failing OEM PLA or
  106. bad RAM. The sub-PLA could be made
  107. to work in some boards by replacing
  108. the VIC, the MPU and/or the CIAs.
  109. For example, a CPU with a later code
  110. date worked in a board with a
  111. sub-PLA whereas the earlier CPU chip
  112. wouldn't even boot up (blank
  113. screen). My oldest 64 board, a 1982
  114. 326298, gave me the most trouble.
  115. Most of the chips in it are early
  116. versions. Swapping some of them out
  117. with newer ones made that board work
  118. fine.
  119.  
  120. The original RAM ICs Commodore used
  121. were either 150nS or 200nS. RAM
  122. chips of a certain speed may work
  123. with the original PLA but not with
  124. the sub-PLA. In one experiment, a
  125. sub-PLA worked with all 200nS RAM,
  126. then one 150nS RAM chip was
  127. substituted, and the bytes free at
  128. startup was reduced although the
  129. original PLA worked fine with that
  130. arrangement. I conclude that C64 ICs
  131. work within a narrow "window" of
  132. acceptable pulse timing, neither too
  133. fast nor too slow. The use of a
  134. substitute PLA in some boards
  135. obviously creates timing errors,
  136. some fatal (blank screen) and others
  137. producing subtle screen "glitches"
  138. and program crashes.
  139.  
  140. If an EPROM works in a particular
  141. board, that's fine. But, what do you
  142. do if no sub-PLA seems to work? One
  143. workaround I found was to add a
  144. small capacitor (one end tied to
  145. ground) to the replacement IC output
  146. pin 18, the \CAS line to the RAM,
  147. which adds a bit of delay to those
  148. pulses. I experimented with values
  149. between 50pF and 220pF and got good
  150. results. The bottom line here is
  151. that whatever board you have may or
  152. may not work 100% with a sub-PLA. It
  153. may need to be "tweaked", and most
  154. users will not want to do that. So,
  155. a drop-in replacement for the
  156. original PLA that will work with all
  157. boards without any problems is still
  158. unavailable.
  159.  
  160. When I repair a C64 that needs a
  161. replacement PLA, I can make the sub
  162. work in most cases with chip swaps,
  163. selecting an optimum speed of the
  164. substitute EPROM and/or by using the
  165. time delay capacitor. Testing the
  166. final product involves 1. observing
  167. the bytes free on the opening screen
  168. to see if it's normal, 2. looking
  169. for "glitches", random colour shifts
  170. or odd characters anywhere on the
  171. screen while a program is running,
  172. 3. testing with several different
  173. cartridges such as CBM Jupiter
  174. Lander (which refused to load in one
  175. board when everything else seemed to
  176. work) and a passing grade using the
  177. C64 diagnostic cart some kind soul
  178. gave me years ago.
  179.  
  180. Making the substitute PLA is pretty
  181. straightforward. With a few pins
  182. rewired via an adaptor (schematic is
  183. readpla.jpg) I made with two
  184. "sandwiched" IC sockets, I used my
  185. ERPOM burner to copy the code from a
  186. working PLA chip. The burner reads
  187. it as if it were a 27C512 EPROM and
  188. the resulting file pla.bin has a
  189. checksum of hex DAA0. That code was
  190. burned into a standard 27C512 EPROM.
  191. I then used another cross-wired
  192. adaptor (schematic is eprompla.jpg)
  193. to install the EPROM in my C64. The
  194. files mentioned above are on my
  195. schematics website at
  196. http://staff.washington.edu/rrcc/
  197. uwweb/eprompla/
  198.  
  199. One last thing... replacing a PLA
  200. with an EPROM in an adaptor socket
  201. that plugs into a board-mounted IC
  202. socket may cause intermittent
  203. operation if the board socket has
  204. loose contacts. One way around that
  205. is to use an adaptor socket with
  206. round pins that are thicker than the
  207. standard replacement types. Of
  208. course the mod PLA socket can be
  209. soldered into the C64 board
  210. directly. It's likely to be the last
  211. time it will be replaced anyway...
  212. as long as it works correctly the
  213. first time it's installed. It
  214. doesn't need to be heat sinked like
  215. the original PLA should have been...
  216. the new chip runs cool.
  217.  
  218. Ray Carlsen
  219.  
  220. Much appreciated for the info Ray.
  221.  
  222. Since I'm using a Promenade C1, I
  223. had to break the file into two 32k
  224. sections as there is NO WAY to
  225. program an entire 64k file with a
  226. Promenade C1. Each file will need
  227. "00 20" inserted into the Beginning
  228. of the file, they will be 32770
  229. bytes in size.
  230.  
  231. In order to program a 27c512 EPROM.
  232. BEST to use -45ns for the PLA. you
  233. will have to run a ground wire from
  234. the CASE of the Promenade C1 to PIN
  235. #1 on the IC. This will allow you to
  236. program the FIRST HALF (32k) of the
  237. EPROM. Remove the wire to program
  238. the SECOND HALF of the EPROM.
  239.  
  240. I am using Promshell to do this. You
  241. can find the disk on my FTP site :
  242. ftp://www.n2dvm.com//Commodore/
  243. Programs/Eprom/promshell.zip
  244.  
  245. Here are the files I used for the
  246. PLA. They already have the "00 20"
  247. added to them to make it easier on
  248. you.
  249.  
  250. ftp://www.n2dvm.com/Commodore/
  251. Programs/Eprom/PLA-Files.rar
  252.  
  253. Have fun.
  254.  
  255. ====================================
  256.